package ac.zlf.springmybatis.constant;

/**
 * Created by Administrator on 2017/4/16 0016.
 */
public enum Indicator {

    MENU_GRADE_1(1, "第一级"), MENU_GRADE_2(2, "第二级"), MENU_GRADE_3(3, "第三级"),

    STATUS_1(1,"正常"), STATUS_2(1,"删除"),

    ;

    private Integer code;
    private String msg;

    private Indicator(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public boolean isCode(Integer code) {
        if(code == null){
            return false;
        }
        if(this.code == code){
            return true;
        }else{
            return false;
        }
    }
}
